package com.gtxc.kotlinmvvm.ui.activity;

import android.graphics.Color;
import android.os.Bundle;
import android.view.View;
import android.widget.PopupWindow;

import androidx.recyclerview.widget.LinearLayoutManager;

import com.aleyn.mvvm.base.BaseActivity;
import com.gtxc.kotlinmvvm.R;
import com.gtxc.kotlinmvvm.adapater.AgencyAdapater;
import com.gtxc.kotlinmvvm.adapater.MyFenSiAdapater;
import com.gtxc.kotlinmvvm.databinding.ActivityAgencyBinding;

import com.gtxc.kotlinmvvm.network.request.DaiLiBean;

import com.gtxc.kotlinmvvm.viewmodle.AgencyViewModle;
import com.gtxc.kotlinmvvm.BR;
import org.jetbrains.annotations.Nullable;

import java.util.ArrayList;
import java.util.List;

/**
 * FileName:AgencyActivity
 * Author：Administrator
 * Date:2021 2021/9/30 14:13
 * Copyright (C), 2020-2021,成都拇音科技有限公司
 * <p>
 * <p>
 * Description: 代理页面
 * History:
 * <author> <time> <version> <desc>
 * 作者姓名 修改时间 版本号 描述
 */
//代理
public class AgencyActivity extends BaseActivity<AgencyViewModle, ActivityAgencyBinding> {
    private List<DaiLiBean>  lists=new ArrayList<>();
    private AgencyAdapater adapter;
    @Override
    public int layoutId() {
        return R.layout.activity_agency;
    }

    @Override
    public void initView(@Nullable Bundle savedInstanceState) {
        getMBinding().toolbar.setTitleBackgroundColor(Color.WHITE);
        getMBinding().toolbar.setLeftBackgroundColor(R.mipmap.left_back);
        getMBinding().toolbar.setOnLeftClickListener(v -> finish());
        LinearLayoutManager manager =new LinearLayoutManager(this);
        manager.setOrientation(LinearLayoutManager.VERTICAL);

        getMBinding().recyerview.setLayoutManager(manager);
        adapter =new AgencyAdapater(R.layout.daili_itma);
        adapter.addData(lists);
        getMBinding().recyerview.setAdapter(adapter);
    }

    @Override
    public void initData() {

    }

    @Override
    public void initCLick() {

    }

    @Override
    public int variableID() {
        return BR.AgencyViewModle;
    }

    @Override
    public void bindViewModel() {

    }
}
